<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="UTF-8">
<title>文件上传下载</title>
<link rel="stylesheet" th:href="@{css/bootstrap.min.css}" />
<!-- 默认访问 src/main/resources/static下的css文件夹-->
<link rel="stylesheet" th:href="@{css/bootstrap-theme.min.css}" />

<!--/*--> 
  <!-- 以下用于开发时本地预览 -->
<!--*/-->
<!--/*-->
<link rel="stylesheet" href="../static/css/bootstrap.min.css" />
<link rel="stylesheet" href="../static/css/bootstrap-theme.min.css" />
<!--*/-->
</head>
<body>
<div class="panel panel-primary">
		<div class="panel-heading">
			<h3 class="panel-title">文件上传</h3>
		</div>
	</div>
	<div class="container">
		<div th:each=" message : ${messages} ">
			<h5 th:text="${message}">上传成功</h5>
		</div>
		<div class="row">
			<div class="col-md-6 col-sm-6">
				<form class="form-horizontal" th:action="@{/upload}" method="POST" enctype="multipart/form-data">
					<div class="form-group">
						<div class="input-group col-md-6">
							<span class="input-group-addon">
								<i class="glyphicon glyphicon-search"></i>
							</span>
							<input class="form-control" type="file" name="files" multiple="multiple" value="请选择文件" />
						</div>
					</div>
					<div class="form-group">
						<div class="col-md-6">
							<div class="btn-group btn-group-justified">
								<div class="btn-group">
									<button type="submit" class="btn btn-success">
										<span class="glyphicon glyphicon-share"></span>
										&nbsp;上传文件
									</button>
								</div>
							</div>
						</div>
					</div>
				</form>				
			</div>
		</div>
	</div>
	<div class="container">
		<ul>
			<li th:each="file : ${files}">
				<a th:href="${file}" th:text="${file}" >文件</a>
			</li>
		</ul>
	</div>
</body>
</html>